﻿
namespace ParaEditor.Domain.Entities
{
    public class BenfInfoPk
    {
        public virtual string benfId { get; set; } //stationinfo版本号
        public virtual int benfVer { get; set; }//车站编号


        /// <summary>
        /// 判断两个对象是否相同，这个方法需要重写
        /// </summary>
        /// <param name="obj">进行比较的对象</param>
        /// <returns>真true或假false</returns>
        public override bool Equals(object obj)
        {
            if (obj is BenfInfoPk)
            {
                BenfInfoPk pk = obj as BenfInfoPk;
                if (this.benfVer == pk.benfVer
                     && this.benfId.Equals(pk.benfId))
                {
                    return true;
                }
                else
                {
                    return false;
                }
            }
            return false;
        }

        public override int GetHashCode()
        {
            return base.GetHashCode();
        }
    }
}
